home *** CD-ROM | disk | FTP | other *** search
/ Amiga Games: Greatest Hits 1996 / Amiga Games: Greatest Hits 1996.iso / multimedia / workbench / magicstartmenu / install magicstartmenu < prev    next >
Text File  |  1996-07-27  |  6KB  |  225 lines

  1. ; MagicStartMenu Installation Script
  2. ; Copyright © 1996 by Ralph Torchia
  3. ; $VER:MagicStartMenu v1.0 (07-23-96)
  4.  
  5. (set @PRGVersion "1.0")
  6. (set @logo-choice "logo.bru")
  7. (set @default-dest "SYS:")
  8.  
  9. ;
  10. ; Let's Introduce ourselves
  11. ;
  12.  
  13. (welcome
  14.   ("\nWelcome to the Magic StartMenu %s installer script.\n\n" @PRGVersion)
  15.   ("    MagicStartMenu documentation comes in AmigaGuide format.  Make sure to read this in order to complete the installation process.\n")
  16.   ("    Follow the installer script's instructions to install Magic StartMenu.\n")
  17. )
  18.  
  19. ;
  20. ; Where is StartMenu located???
  21. ;
  22.  
  23. (set @default-dest
  24.   (askdir
  25.     (prompt "Where is the StartMenu Drawer Located?")
  26.     (help "The install script needs to know where the StartMenu drawer is found on your system.")
  27.     (default @default-dest)
  28.   )
  29. )
  30.  
  31. ;
  32. ; Is the StartMenu drawer really where the user said it is???
  33. ;
  34.  
  35. (if (<> (exists (tackon @default-dest "StartMenu")) 2)
  36.     (exit "The StartMenu drawer is not located here!\nInstallation is halted." (quiet))
  37. )
  38.  
  39. ;
  40. ; Give the user a choice of a Logo
  41. ;
  42.  
  43. (message "There are 3 logos that you can choose from.\n  Press \"Proceed\" to see a sample picture...")
  44. (run "SYS:utilities/multiview logosample.iff")
  45.  
  46. (
  47.   (set @choice
  48.     (askchoice
  49.       (prompt "Which logo would you like to have installed for StartMenu?")
  50.       (choices ("1 - White Amiga Text")
  51.                ("2 - Colour Gradiant Bkgd")
  52.               ("3 - Black Amiga Text")
  53.       )
  54.      (help "Choice 1 is my favourite...")
  55.     )
  56.   )
  57.   (if (= @choice 0) (set @logo-choice "logo.bru"))
  58.   (if (= @choice 1) (set @logo-choice "logo2.bru"))
  59.   (if (= @choice 2) (set @logo-choice "logo3.bru"))
  60. )
  61.  
  62.  
  63. ;
  64. ; Copy the all the main files to the StartMenu drawer
  65. ;
  66.  
  67. (copyfiles
  68.   (prompt "Copying icon/brushes to %s" (tackon @default-dest "StartMenu"))
  69.   (help @copyfiles-help)
  70.   (source "Main")
  71.   (pattern "#?")
  72.   (dest (tackon @default-dest "StartMenu"))
  73. )
  74.  
  75. ;
  76. ; If StartMenuLite is present then copy the necessary files
  77. ;
  78.  
  79. (if (= (exists (tackon @default-dest "StartMenu/StartMenuLite.info")) 1)
  80.   ((copyfiles
  81.     (prompt "Copying icon to %s" (tackon @default-dest "StartMenuLite"))
  82.     (help @copyfiles-help)
  83.     (source (tackon "Main/" "StartMenu.info"))
  84.     (dest (tackon @default-dest "StartMenu"))
  85.     (newname "StartMenuLite.info")
  86.    )
  87.   (tooltype
  88.     (prompt "Re-Setting PATH tooltype for StartMenuLite Icons.")
  89.     (help "StartMenu requires the PATH tooltype set to the directory to where it is located.")
  90.     (dest (tackon @default-dest "StartMenu/StartMenuLite"))
  91.     (settooltype "PATH" (tackon @default-dest "StartMenu"))
  92.   ))
  93. )
  94.  
  95. ;
  96. ; If StartMenuUlraLite is present then copy the necessary files
  97. ;
  98.  
  99. (if (= (exists (tackon @default-dest "StartMenu/StartMenuUltraLite.info")) 1)
  100.   ((copyfiles
  101.     (prompt "Copying icon to %s" (tackon @default-dest "StartMenuUltraLite"))
  102.     (help @copyfiles-help)
  103.     (source (tackon "Main/" "StartMenu.info"))
  104.     (dest (tackon @default-dest "StartMenu"))
  105.     (newname "StartMenuUltraLite.info")
  106.   )
  107.   (tooltype
  108.     (prompt "Re-Setting PATH tooltype for StartMenuUltraLite Icons.")
  109.     (help "StartMenu requires the PATH tooltype set to the directory to where it is located.")
  110.     (dest (tackon @default-dest "StartMenu/StartMenuUltraLite"))
  111.     (settooltype "PATH" (tackon @default-dest "StartMenu"))
  112.   ))
  113. )
  114.  
  115. ;
  116. ; Don't forget to reset the StartMenu icon PATH tooltype
  117. ;
  118.  
  119. (tooltype
  120.   (prompt "Re-Setting PATH tooltype for StartMenu Icons.")
  121.   (help "StartMenu requires the PATH tooltype set to the directory to where it is located.")
  122.   (dest (tackon @default-dest "StartMenu/StartMenu"))
  123.   (settooltype "PATH" (tackon @default-dest "StartMenu"))
  124. )
  125.  
  126. ;
  127. ; We don't need these logo files that we copied
  128. ;
  129.  
  130. (delete (tackon @default-dest "StartMenu/logo2.bru"))
  131. (delete (tackon @default-dest "StartMenu/logo3.bru"))
  132.  
  133. ;
  134. ; Copy the appropriate logo file
  135. ;
  136.  
  137. (copyfiles
  138.   (prompt "Copying logo to %s" (tackon @default-dest "StartMenu"))
  139.   (help @copyfiles-help)
  140.   (source (tackon "Main/" @logo-choice))
  141.   (dest (tackon @default-dest "StartMenu"))
  142.   (newname "logo.bru")
  143. )
  144.  
  145. ;
  146. ; Copy all of the brush files
  147. ;
  148.  
  149. (copyfiles
  150.   (prompt "Copying brushes to %s" (tackon @default-dest "StartMenu/Brushes"))
  151.   (help @copyfiles-help)
  152.   (source "Brushes")
  153.   (pattern "#?")
  154.   (dest (tackon @default-dest "StartMenu/Brushes"))
  155. )
  156.  
  157. ;
  158. ; Copy all the new icons to the Extras directory
  159. ;
  160.  
  161. (copyfiles
  162.   (prompt "Copying icons to %s" (tackon @default-dest "StartMenu/Extras"))
  163.   (help @copyfiles-help)
  164.   (source "Extras")
  165.   (dest (tackon @default-dest "StartMenu/Extras"))
  166.   (pattern "#?")
  167. )
  168.  
  169. ;
  170. ; Set new icons for WinControl in the StartUp
  171. ;
  172.  
  173. (if (= (exists (tackon @default-dest "StartMenu/Startup/WinControl.info")) 1)
  174.   (copyfiles
  175.     (prompt "Copying icon to %s" (tackon @default-dest "StartMenu/Startup/WinControl"))
  176.     (help @copyfiles-help)
  177.     (source (tackon "Extras/WinControl" "WinControl.info"))
  178.     (dest (tackon @default-dest "StartMenu/Startup"))
  179.    )
  180. )
  181.  
  182. ;
  183. ; Is WCPrefs in the SYS:Prefs with an ugly icon?
  184. ;
  185.  
  186. (if (= (exists "SYS:Prefs/WCPrefs") 1)
  187.   (copyfiles
  188.     (prompt "Copying WCPref icon to SYS:Prefs")
  189.     (help @copyfiles-help)
  190.     (source (tackon "Extras/WinControl" "WCPrefs.info"))
  191.     (dest "SYS:Prefs")
  192.   )
  193. )
  194.  
  195. ;
  196. ; Set new icons for WinMaster in the Startup
  197. ;
  198.  
  199. (if (= (exists (tackon @default-dest "StartMenu/Startup/WinMaster.info")) 1)
  200.   (copyfiles
  201.     (prompt "Copying icon to %s" (tackon @default-dest "StartMenu/Startup/WinMaster"))
  202.     (help @copyfiles-help)
  203.     (source (tackon "Extras/WinMaster" "WinMaster.info"))
  204.     (dest (tackon @default-dest "StartMenu/Startup"))
  205.    )
  206. )
  207.  
  208. ;
  209. ; Don't forget to Copy the new StartMenu drawer icon!!!
  210. ;
  211.  
  212. (copyfiles
  213.   (prompt "Copying icon to %s" (tackon @default-dest "StartMenu"))
  214.   (help @copyfiles-help)
  215.   (source "/MagicStartMenu.info")
  216.   (dest @default-dest)
  217.   (newname "StartMenu.info")
  218. )
  219.  
  220. ;
  221. ; Bye-Bye!
  222. ;
  223.  
  224. (exit)
  225.